package id.net.iconpln.bb.client;

import com.extjs.gxt.ui.client.widget.MessageBox;
import com.google.gwt.http.client.Request;
import com.google.gwt.http.client.RequestBuilder;
import com.google.gwt.http.client.RequestCallback;
import com.google.gwt.http.client.Response;

public class BbClientUtil {

	public static void requestUtil(String url, String message){
//		WidgetController.getInstance().maskCenter(message);
		RequestBuilder builder = new RequestBuilder(RequestBuilder.GET,url);
		try {
			Request response = builder.sendRequest(null, new RequestCallback() {

				@Override
				public void onError(Request request, Throwable exception) {
					// TODO Auto-generated method stub
					
				}

				@Override
				public void onResponseReceived(Request request, Response response) {
					// TODO Auto-generated method stub
					
				}
			
			});
		} catch (Exception e) {
			MessageBox.alert("Error", "Unable to build request", null);
		}
	}
}
